\hypertarget{classjost_1_1Parser}{
\section{jost::Parser Class Reference}
\label{classjost_1_1Parser}\index{jost::Parser@{jost::Parser}}
}


{\ttfamily \#include $<$Parser.hpp$>$}



Collaboration diagram for jost::Parser:\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=400pt]{classjost_1_1Parser__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{classjost_1_1Object}{jost::Object} $\ast$ \hyperlink{classjost_1_1Parser_a014d537397e4898c3abaaf08375470ca}{parse} (const std::string \&stream)  throw (jost::MalformedJSONStream)
\item 
\hyperlink{classjost_1_1Object}{jost::Object} $\ast$ \hyperlink{classjost_1_1Parser_a30abf07c37ef810f24f78b58d8f3f6cb}{parse} (std::istream \&stream)  throw (jost::MalformedJSONStream)
\item 
\hyperlink{classjost_1_1Object}{jost::Object} $\ast$ \hyperlink{classjost_1_1Parser_a612b84d470305c26dcf28c6c84a3de9c}{parse} (const char $\ast$stream)  throw (jost::MalformedJSONStream)
\end{DoxyCompactItemize}
\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classjost_1_1Parser_a24a5f96d744295376b1a5bbc8b24203b}{
static \hyperlink{classjost_1_1Parser}{Parser} \& {\bfseries instance} ()  throw ()}
\label{classjost_1_1Parser_a24a5f96d744295376b1a5bbc8b24203b}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
The {\ttfamily \hyperlink{classjost_1_1Parser}{Parser}} is a singleton class that provides a wrapper over the functionalities provided by Spirit and JOST core classes for parsing JSON Objects.\par


JSON Objects might be provided as {\ttfamily std::string} or as {\ttfamily std::istream}.

\begin{DoxyAuthor}{Author}
Angelo Corsaro $<$mailto:\href{mailto:angelo.corsaro@gmail.com}{\tt angelo.corsaro@gmail.com}$>$ 
\end{DoxyAuthor}
\begin{DoxyVersion}{Version}
0.1 
\end{DoxyVersion}


Definition at line 45 of file Parser.hpp.



\subsection{Member Function Documentation}
\hypertarget{classjost_1_1Parser_a612b84d470305c26dcf28c6c84a3de9c}{
\index{jost::Parser@{jost::Parser}!parse@{parse}}
\index{parse@{parse}!jost::Parser@{jost::Parser}}
\subsubsection[{parse}]{\setlength{\rightskip}{0pt plus 5cm}{\bf jost::Object} $\ast$ jost::Parser::parse (const char $\ast$ {\em stream})  throw (jost::MalformedJSONStream)}}
\label{classjost_1_1Parser_a612b84d470305c26dcf28c6c84a3de9c}
Parse an {\ttfamily \hyperlink{classjost_1_1Object}{Object}} from a {\ttfamily const char$\ast$}


\begin{DoxyParams}{Parameters}
\item[{\em stream}]the JSON object stream \end{DoxyParams}
\begin{DoxyReturn}{Returns}
the parsed {\ttfamily \hyperlink{classjost_1_1Object}{Object}} 
\end{DoxyReturn}

\begin{DoxyExceptions}{Exceptions}
\item[{\em jost::MalformedJSONStream}]in case the stream is malformed. \end{DoxyExceptions}


Definition at line 19 of file Parser.cpp.

\hypertarget{classjost_1_1Parser_a30abf07c37ef810f24f78b58d8f3f6cb}{
\index{jost::Parser@{jost::Parser}!parse@{parse}}
\index{parse@{parse}!jost::Parser@{jost::Parser}}
\subsubsection[{parse}]{\setlength{\rightskip}{0pt plus 5cm}{\bf jost::Object} $\ast$ jost::Parser::parse (std::istream \& {\em stream})  throw (jost::MalformedJSONStream)}}
\label{classjost_1_1Parser_a30abf07c37ef810f24f78b58d8f3f6cb}
Parse an {\ttfamily \hyperlink{classjost_1_1Object}{Object}} from a {\ttfamily std::istream}


\begin{DoxyParams}{Parameters}
\item[{\em stream}]the JSON object stream \end{DoxyParams}
\begin{DoxyReturn}{Returns}
the parsed {\ttfamily \hyperlink{classjost_1_1Object}{Object}} 
\end{DoxyReturn}

\begin{DoxyExceptions}{Exceptions}
\item[{\em jost::MalformedJSONStream}]in case the stream is malformed. \end{DoxyExceptions}


Definition at line 43 of file Parser.cpp.

\hypertarget{classjost_1_1Parser_a014d537397e4898c3abaaf08375470ca}{
\index{jost::Parser@{jost::Parser}!parse@{parse}}
\index{parse@{parse}!jost::Parser@{jost::Parser}}
\subsubsection[{parse}]{\setlength{\rightskip}{0pt plus 5cm}{\bf jost::Object} $\ast$ jost::Parser::parse (const std::string \& {\em stream})  throw (jost::MalformedJSONStream)}}
\label{classjost_1_1Parser_a014d537397e4898c3abaaf08375470ca}
Parse an {\ttfamily \hyperlink{classjost_1_1Object}{Object}} from a {\ttfamily std::string}


\begin{DoxyParams}{Parameters}
\item[{\em stream}]the JSON object stream \end{DoxyParams}
\begin{DoxyReturn}{Returns}
the parsed {\ttfamily \hyperlink{classjost_1_1Object}{Object}} 
\end{DoxyReturn}

\begin{DoxyExceptions}{Exceptions}
\item[{\em jost::MalformedJSONStream}]in case the stream is malformed. \end{DoxyExceptions}


Definition at line 37 of file Parser.cpp.



The documentation for this class was generated from the following files:\begin{DoxyCompactItemize}
\item 
src/jost/Parser.hpp\item 
src/jost/Parser.cpp\end{DoxyCompactItemize}
